package com.fourth.controller.oss;


import com.ljx.utils.OssUtil1;
import com.ljx.vo.Result;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;

/**
 * @author C-Q
 * @version 1.1.0
 * @Description: TODO
 * @date 2023/3/3
 */
@RestController
@RequestMapping("/merchant/ossPhoto")
public class OssPhoto {
        @RequestMapping("/upload")
        @ResponseBody
        public Result upload(MultipartFile file) throws Exception {
            String path = OssUtil1.ossUpload(file);
            return new Result(2000,"上传成功",path);
        }
    }

